﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

namespace ordserv
{
    public partial class frmCidadeEdit : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }


        // Documentar
        protected void FormView1_ItemUpdated(object sender, FormViewUpdatedEventArgs e)
        {
            if (e.Exception == null)
            {
                Response.Redirect("frmCidade.aspx");
            }
        }

        protected void FormView1_ItemCommand(object sender, FormViewCommandEventArgs e)
        {
            if (e.CommandName == "Cancel")
            {
                Response.Redirect("frmCidade.aspx");
            }
        }

        protected void FormView1_ItemInserted(object sender, FormViewInsertedEventArgs e)
        {
            if (e.Exception == null)
            {
                Response.Redirect("frmCidade.aspx");
            }
        }

       // protected void CustomValidator1_ServerValidate(object source, ServerValidateEventArgs args)
        //{
            // cONVERTO O SOURCE QUE É OBJECT PARA tEXTbOX
            // TextBox tx = (TextBox)source;

            // Valida se o nome possui mais de 3 caracteres 
         //   args.IsValid = args.Value.Length > 3;
       // }
    }
}
